Previous Book Contents Book Index Next

Inside Macintosh: QuickDraw GX Objects /
Chapter 7 - View-Related Objects / View-Related Objects Reference
View Group Functions / Getting the View Ports and View Devices of a View Group


GXGetViewGroupViewPorts

You can use the GXGetViewGroupViewPorts function to retrieve a list of the view ports that are associated with a view group object.

long GXGetViewGroupViewPorts(gxViewGroup source, 
                              gxViewPort list[]);
source
A reference to the view group whose view ports you wish to examine.
list
An array of view port references. On return, the array contains a list of references to the view ports belonging to the source view group.
function result
The number of view port references in the list array.
DESCRIPTION
The GXGetViewGroupViewPorts function fills out a list of all the view ports in the source view group and returns, as its function result, the number of view ports in the list.

If you pass gxAllViewDevices for the source parameter, this function returns all view ports in all view groups.

If you set the list parameter to nil, GXGetViewGroupViewPorts does not fill out the list of references; it only returns the number of view port references that would be
in the list. Thus, you typically call this function twice: first to get the size of array to allocate for the list parameter, and second to retrieve the list itself.

ERRORS, WARNINGS, AND NOTICES
Errors 
invalid_viewGroup_reference 
SEE ALSO
To get a list of all the view devices in a view group, use the GXGetViewGroupViewDevices function, described next.


Previous Book Contents Book Index Next

© Apple Computer, Inc.
7 JUL 1996